home *** CD-ROM | disk | FTP | other *** search
/ Sprite 1984 - 1993 / Sprite 1984 - 1993.iso / src / cmds / gcore / RCS / gcore.man,v < prev    next >
Encoding:
Text File  |  1989-02-06  |  2.9 KB  |  95 lines

  1. head     1.1;
  2. branch   ;
  3. access   ;
  4. symbols  ;
  5. locks    ; strict;
  6. comment  @@;
  7.  
  8.  
  9. 1.1
  10. date     89.02.05.20.51.07;  author mendel;  state Exp;
  11. branches ;
  12. next     ;
  13.  
  14.  
  15. desc
  16. @The gcore program.
  17. @
  18.  
  19.  
  20.  
  21. 1.1
  22. log
  23. @Initial revision
  24. @
  25. text
  26. @'\" Copyright 1989 Regents of the University of California
  27. '\" Permission to use, copy, modify, and distribute this
  28. '\" documentation for any purpose and without fee is hereby
  29. '\" granted, provided that this notice appears in all copies.
  30. '\" The University of California makes no representations about
  31. '\" the suitability of this material for any purpose.  It is
  32. '\" provided "as is" without express or implied warranty.
  33. '\" 
  34. '\" $Header: /sprite/lib/forms/RCS/proto.man,v 1.5 89/01/27 08:36:02 ouster Exp $ SPRITE (Berkeley)
  35. '/" 
  36. .so \*(]ltmac.sprite
  37. .HS <GCORE> cmds
  38. .BS
  39. .SH NAME
  40. gcore \- Generate a core file from a Sprite process.
  41. .SH SYNOPSIS
  42. .nf
  43. \fBgcore\fR [\fIoptions\fR] \fIpid pid ...\fR
  44. .SH OPTIONS
  45. .IP "\fB\-o\fI prefix\fR" 10
  46. Generate the output file names by prepending the string 
  47. \fIprefix\fR to each of the pids.
  48. .IP "\fB\-k\fR"
  49. Kill the process after the core dump is produced.
  50. .IP "\fB\-s \fIsignal\fR"
  51. Use signal number \fIsignal\fR to pause running process.
  52. .BE
  53.  
  54. .SH DESCRIPTION
  55. .PP
  56. \fBGcore\fR generates a snapshot of the current execution state
  57. of a Sprite process.
  58. For historical reasons,
  59. these snapshot are referred to as core dumps or core files.
  60. Core dumps can be used by the \fBgdb\fR debugger to 
  61. examine the process's state as if the debugger was attached
  62. to the process.
  63. .LP
  64. \fBGcore\fR takes as arguments one or more process ids and 
  65. generates core dumps for each process in the file core.\fIpid\fR
  66. where \fIpid\fR is the specified process id.
  67. The \fB-o\fR option allows a string other than "core" to be
  68. used to generate output file names.
  69. If the \fB-k\fR option is specified, the processes specified will
  70. be sent a SIGKILL signal after the core dump is finished. 
  71. .LP
  72. \fBGcore\fR reads the register state and memory image of a
  73. process by using the Sprite debugger 
  74. interface (\fBProc_Debug\fR.) 
  75. If the process is not already in the DEBUG state (see the \fBps\fR command),
  76. \fBgcore\fR will send the process a SIGTRAP signal to force 
  77. it into the DEBUG state.  
  78. This operation will fail if the user does not have permission to 
  79. send signals to the process or the 
  80. process has blocked, ignored, or has a handler installed for the SIGTRAP signal.
  81. The \fB-s\fR option can be used to inform \fBgcore\fR
  82. to use a signal number other than 5 (SIGTRAP).
  83. Other signals that may work are 4 (SIGILL), 8 (SIGFPE) and 11 (SIGSEGV).
  84. \fBGcore\fR restarts running process by sending them a SIGCONT after
  85. the dump is produced.
  86. .SH WARNING
  87. The signals used by \fBgcore\fR  to stop running processes
  88. can interrupt system calls such 
  89. as \fBread, select\fR, or \fBsleep\fR, 
  90. causing them to return an error status of EINTR. 
  91. Some programs may interpret the EINTR as an error and exit.
  92. .SH KEYWORDS
  93. gdb, coredump
  94. @
  95.